package com.mvd.app.widget;

import android.content.Context;
import android.util.AttributeSet;
import android.view.MotionEvent;
import android.widget.ScrollView;

/**
 * @ProjectName: PDA_New_2019_WenZhou
 * @Package: com.mvd.app.widget
 * @ClassName: MyScrollView
 * @Description: java类作用描述
 * @Author: liuxj
 * @CreateDate: 2020-06-10 9:15
 * @UpdateUser: 更新者
 * @UpdateDate: 2020-06-10 9:15
 * @UpdateRemark: 更新说明
 * @Version: 1.0
 */
public class MyScrollView extends ScrollView {
    public MyScrollView(Context context) {
        this(context,null);
    }
    public MyScrollView(Context context, AttributeSet attrs) {
        this(context, attrs,0);
    }
    public MyScrollView(Context context, AttributeSet attrs, int defStyleAttr) {
        super(context, attrs, defStyleAttr);
    }
    @Override
    public boolean onInterceptTouchEvent(MotionEvent ev) {
        //关键点在这
        getParent().requestDisallowInterceptTouchEvent(true);
        return super.onInterceptTouchEvent(ev);
    }
}